<?php 
defined('_JEXEC') or die('Restricted access');

$lang =& JFactory::getLanguage();
//$template_dir = $this->baseurl.'/templates/mwc_careitec/assets/';
$template_dir = '/templates/mwc_careitec/assets/';
jimport('mylibs.function');
jimport('mylibs.globalModel');
$globalModel = new globalModel();
?>   

<script src="<?php echo $template_dir; ?>scripts/jScroll_1.js" type="text/javascript" ></script>
<script src="<?php echo $template_dir; ?>scripts/jScroll_2.js" type="text/javascript" ></script>
<script type="text/javascript">
    jQuery(document).ready(function(){
        jQuery('#pane').jScrollPane({scrollbarWidth: 20});
    });
</script>

<?php
if($_SERVER['HTTP_REFERER'] != ''){
    $referer = $_SERVER['HTTP_REFERER'];    
}   
else{
    $referer = 'javascript:history.go(-1);';
} 
?>

<div id="main" class="p15t">
    <div class="w214 float_left">
        <div class="w214 left_menu m10b">
            <div class="left_menu">
                <!--{mo dule OnlineSupport}-->
                <ul>
                    <?php 
                    $arr_data = $globalModel->getSubMenu('News');
                    foreach( $arr_data as $key => $value){    
                        $selected = '';                            
                        if(JRequest::getVar('Itemid', 0, 'get') == $value['id']){
                            $selected = ' class="curr_left_menu"';
                        }                                                                                                   
                        ?>    
                        <li <?php echo $selected; ?>><a href="<?php echo $value['link']."&Itemid=".$value['id'];?>" ><?php echo $value['name'];?></a></li>
                    <?php } ?> 
                </ul>
            </div>
            <div class="left_menu_bot"></div>
        </div>
        <div class="w214 po m10b">

            <div class="w214 bg_top_box_mid">
                <div class="w214 bg_top_box">
                    <div class="mc w186 p10t p15b">
                        <?php 
                        $arr_data2 = $globalModel->getArticle(57);
                        foreach ( $arr_data2 as $key => $value ){    
                        ?> 
                            <h2 class="organ_text upper">
                                <b><?php echo $value['title'];?></b>
                            </h2>
                            <div class="p5t"><?php echo $value['introtext'];?></div>
                        <?php } ?>  

                        <div class="button_book p5t">
                            <a href="index.php?option=com_user&view=book"><img src="<?php echo $template_dir; ?>images/book_button.png" alt="" /></a>            
                        </div>
                    </div>
                </div>
                <div class="w214 bg_bottom_box"></div>
            </div>
        </div>
        <div class="w214">
            <div class="ads_sub_top"></div>
            <div class="ads_sub_mid">
                <div class="w186 mc p10t p10b">
                    <a href="intel_details.html"><img src="<?php echo $template_dir; ?>images/banner_ads_sub.jpg" alt="" /></a>
                    <p class="p5t">Lorem Ipsum er ganske enkelt fyldtekst fra print- og typografiindustrien. Lorem Ipsum har været standard fyldtekst siden 1500-tallet...<a href="intel_details.html">mere</a></p>
                </div>
            </div>
            <div class="ads_sub_bot"></div>
        </div>
    </div>
    <div class="w708 bg_left_col2 float_right p22l">
        <div class="w708 bg_tt_sub1">
            <h2 class="p5t float_left"><?php echo $this->article->title; ?></h2>
            <p class="float_right p5t" style="display:none"><a href="<?php echo $referer; ?>"><img src="<?php echo $template_dir; ?>images/tilbage_icon.png" alt="" /> Tilbage</a></p>
            <br style="clear:both" />
        </div>
        <div class="osX w708">
            <div class="w708 scroll-pane" id="pane1">
                <?php if($this->article->article_image != '') { ?>
                    <img src="<?php echo $this->article->article_image ; ?>" alt="" class="float_left m10r m10b"/>
                <?php } ?>
                <?php echo $this->article->text; ?>
            </div>
        </div>

    </div>
    <div class="cb"></div>
</div>

<div id="footer" class="bg_foot_sub">
    <div class="w950 mc p15t p15b">
        <p class="float_left">Copyright © <?php echo date('Y'); ?> <a href="<?php echo $this->baseurl; ?>">CAREITEC.DK</a>. All rights reserved.</p>
        <p class="float_right">Design by <a href="http://www.mywebcreations.dk/" target="_blank">My Web Creations</a></p>
        <br style="clear:both" />
    </div>
    </div>
  </div>
</div>
